<?php

use App\Models\Images;
use Faker\Factory;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\DB;

class ImagesTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        factory(Images::class, 50)->create()->each(function($u) {
            $u->posts()->save(factory(Images::class)->make());
        });
    }
}
